1. Field of the Disclosure
The present disclosure is directed to a method for power-saving and more particularly, to a power-saving method applicable to an embedded controller.
2. Description of Related Art
Power management is an important function of a common desktop computer and a portable peripheral device (such as a notebook computer), which relies on power supplied by batteries. How to effectively reduce power usage of inactive equipments with respect to operating conditions of computer devices and peripheral equipments, so as to improve efficiency and extend lifetime of batteries is particularly critical to power management.
In order to maintain a common power management interface between operating systems and hardware, an advanced configuration and power interface (ACPI) standard has been developed to improve efficiency of power management based on interactions between the user and the operating system. When the operation system is aware that certain functions in the computer are currently inactive, the functions may be automatically terminated to reduce power consumption to save more power. In the ACPI standard, the embedded controller is configured to control battery power of the computer system and operation states of a plurality of peripheral devices in the computer system to achieve an effect of power-saving.
However, as for the power consumption of the embedded controller, the power consumed by the embedded controller is relatively low to the other elements in the computer system, which is not a factor of affecting the lifespan of the battery. Nevertheless, with the development of the technology, more and more techniques and methods for power saving have been progressive day by day, such that the power consumption of each element in the computer system has gradually lowered down. Meanwhile, with the development of portable electronic products, such as Ultrabook and tablet computers, which are more power-saving, the power consumption of the embedded controllers has become an important issue to be studied.
In a current embedded controller, each task has a different execution period so as to transfer to an active mode with high power consumption from an idle mode. However, the embedded controller transfers to the active mode with high power consumption from the idle mode merely by a timer using the shortest time period. For example, FIG. 1 is a schematic timing diagram illustrating the operation of a conventional embedded controller. In this case, it is assumed that the embedded controller has 5 tasks, wherein the first task has to be executed once per 10 milliseconds (ms), the second task has to be executed once per 20 ms, the third task has to be executed once per 30 ms, the fourth task has to be executed once per 50 ms, the fifth task has to be executed once per 100 ms, and the time required for the embedded controller to process each task is t.
As illustrated in FIG. 1, the embedded controller transfers to the active mode from the idle mode by the timer constantly using the shortest period of 10 ms so as to execute the first task. Then, the embedded controller checks whether each of the other tasks has to be executed. Namely, per 10 ms, the embedded controller requires taking 5t of time to stay in the active mode. Accordingly, the embedded controller requires staying in the active mode and taking time in examining the tasks that do not have to be processed, which result in unnecessary power consumption.